home *** CD-ROM | disk | FTP | other *** search
- * demo.prg
- * demo driver for PAGES.PRG
- * AS 11/17/86
-
- set status off
- set talk off
- close databases
- close procedure
- set procedure to pages
-
- if .not. file("line.dbf")
- @3,0 say "PAGES needs LINE.DBF"
- return
- endif
- if .not. file("curson.bin") .or. .not. file("cursoff.bin")
- @3,0 say "PAGES needs CURSON.BIN and CURSOFF.BIN to run"
- return
- endif
-
- @0,0 say "PAGES demo: A. Schulman, Nov. 1986"
-
- public thisfile
- thisfile = "pages.dat"
-
- do while len(trim(thisfile)) > 0
- do SHOW_REV with thisfile, 1, 0
- do PAGES with thisfile, 1, 19, 3, 1, 2, .T.
- enddo
-
- * if pages doesn't want itself called again, it sets thisfile to "";
- * otherwise it returns a good filename
- * this makes recursion (pages calling itself) unnecessary, but requires
- * that both calling program and pages know about variable thisfile.
- * remember that for pages.src, thisfile is actually parameter FILENAME!
-
- if file("command.com") && will look on path, not just current dir
- @row()-2,0
- run dir > temp.txt
- @0,0 say "A smaller PAGES window, this time looking at your directory,"
- @1,0 say "just to show that any text can be input for PAGES"
- @17,0 clear
- do PAGES with 'temp.txt', 2, 14, 3, 1, 2, .F.
- endif
-
- @row(),0 say "Demo completed: You might need to reopen your old procedure file"